<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<script type="text/javascript">
			//不同类型的数据是不能做运算的

			//-----------------隐式转换--------------------------------------------
			var a = true; //boolean
			console.log(typeof a);

			var b = a + 1; //隐式转换 js引擎
			console.log(b); //2

			var c = "6";
			var d = c - 1; //隐式转换 js引擎
			console.log(d); //5

			d = c + 1; //连接符
			console.log(d);

			//-----------------显示转换--------------------------------------------
		</script>
	</head>
	<body>
	</body>
</html>
